﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

using sapphirelang.AST.Exprs;

namespace sapphirelang.AST.Patterns
{
    // pat when/where guard
    // matches the input against a pattern, then
    // fails if the guard expression does not evaluate to true
    class GuardPattern : Pattern
    {
        public Pattern pat;
        public Expr guard;

        public GuardPattern(Pattern pat, Expr guard)
        {
            this.pat = pat;
            this.guard = guard;
        }
    }
}
